package com.hzj.service;

import com.hzj.pojo.vo.user.UserInfoQueryVo;
import com.hzj.utils.Result;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.stereotype.Service;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

/**
 * @author Aisling
 * @date 2021-05-12 15:03
 */
@Service
@FeignClient(name = "PROVIDER-USER-8001")
public interface AdminService {

    //用户列表
    @PostMapping("/api/user/admin/list/{page}/{limit}")
    public Result findAll(@PathVariable(value = "page") Integer page, @PathVariable(value = "limit") Integer limit, @RequestBody UserInfoQueryVo queryVo);

    //用户锁定
    @PostMapping("/api/user/admin/lock/{id}/{status}")
    public Result lockUser(@PathVariable(value = "id") Integer id,@PathVariable(value = "status") Integer status);

    //用户详情
    @PostMapping("/api/user/admin/show/{id}")
    public Result userDetails(@PathVariable(value = "id") Integer id);

    //认证审批
    @PostMapping("/api/user/admin/approval/{id}/{authStatus}")
    public Result userApproval(@PathVariable(value = "id") Integer id, @PathVariable(value = "authStatus") Integer authStatus);

    //删除用户
    @PostMapping("/api/user/admin/delectUserinfo/{id}")
    public Result deleteUserInfo(@PathVariable(value = "id") Integer id);
}
